package Week6.J0525;

import java.util.*;

public class 提取不重复的整数 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        StringBuffer sbr = new StringBuffer(scanner.next());
        Set<Character> set = new LinkedHashSet<>(); // 用链式集合来保证连续性
        for (int i = sbr.length() - 1; i >= 0; i--) {
            set.add(sbr.charAt(i));
        }
        StringBuffer sbr2 = new StringBuffer();

        for (char c : set) {
            sbr2.append(c - '0');
        }
        System.out.println(sbr2);
    }
}
